import request from '../request'

const Api = {
  page: '/api/admin/semester/page',
  selectList: '/api/admin/semester/selectList',
  remove: '/api/admin/semester/remove',
  save: '/api/admin/semester/save',
  details: '/api/admin/semester/selectById',
  update: '/api/admin/semester/update',
}

export const remove = params => {
  return request.request({
    url: Api.remove,
    params,
    method: 'DELETE'
  })
}
// 学期的分页
export const page = params => {
  return request.request({
    url: Api.page,
    params,
    method: 'GET'
  })
}
// 学期的list
export const selectList = params => {
  return request.request({
    url: Api.selectList,
    params,
    method: 'GET'
  })
}

/** 新增TA管理基本信息 */
export const save = data => {
  return request.request({
    url: Api.save,
    data,
    method: 'POST'
  })
}
/** 修改TA管理基本信息 */
export const update = data => {
  return request.request({
    url: Api.update,
    data,
    method: 'PUT'
  })
}
/** 查看TA管理基本信息 */
export const details = params => {
  return request.request({
    url: Api.details,
    params,
    method: 'GET'
  })
}
